﻿using System;

namespace SharpSqlAnalyzer.nodes
{
	// Token: 0x020002B9 RID: 697
	public class TDeclareVariableList : TParseTreeNodeList
	{
		// Token: 0x060017A4 RID: 6052 RVA: 0x00328675 File Offset: 0x00326875
		public virtual void addDeclareVariable(TDeclareVariable Item)
		{
			base.addElement(Item);
		}

		// Token: 0x060017A5 RID: 6053 RVA: 0x0032867E File Offset: 0x0032687E
		public virtual TDeclareVariable getDeclareVariable(int position)
		{
			if (position < base.size())
			{
				return (TDeclareVariable)this.elementAt(position);
			}
			return null;
		}

		// Token: 0x060017A6 RID: 6054 RVA: 0x00328698 File Offset: 0x00326898
		public virtual void setTypeAndDefaultValueOfEachVariable(TTypeName ptype, TExpression pexpr)
		{
			for (int i = 0; i < base.size(); i++)
			{
				TDeclareVariable declareVariable = this.getDeclareVariable(0);
				declareVariable.Datatype = ptype;
				declareVariable.DefaultValue = pexpr;
			}
		}

		// Token: 0x060017A7 RID: 6055 RVA: 0x003286CA File Offset: 0x003268CA
		internal override void addParseTreeNode(object arg1)
		{
			this.addDeclareVariable((TDeclareVariable)arg1);
		}

		// Token: 0x060017A8 RID: 6056 RVA: 0x003286D8 File Offset: 0x003268D8
		public override void accept(TParseTreeVisitor v)
		{
			v.preVisit(this);
			v.postVisit(this);
		}

		// Token: 0x060017A9 RID: 6057 RVA: 0x003286E8 File Offset: 0x003268E8
		public override void acceptChildren(TParseTreeVisitor v)
		{
			v.preVisit(this);
			for (int i = 0; i < base.size(); i++)
			{
				this.getDeclareVariable(i).acceptChildren(v);
			}
			v.postVisit(this);
		}
	}
}
